<?php
class conf {
    protected static $ins = null;
    protected $data = array();
    final protected __construct() {
        //一次性把配置文件信息读过来，赋给data属性，以后就不用管配置信息了，直接不用管配置文件，再配置，直接从data属性中找
        include('./config.inc.php');
        $this->data =$_CFG;

    }
    final protected __clone() {
        
    }    

    public static function getIns() {
        if(self::$ins instanceof self){
            return self::$ins;
        }else{
            self:$ins=new self();
            return self::$ins;
        }
    }
}